package vo {
	import mx.collections.ArrayCollection;
	import org.davekeen.flextrine.orm.FlextrineError;
	
	[Bindable]
	public class PhoneNumberEntityBase {
		
		[Transient]
		public var __isUnserialized__:Boolean;
		
		[Transient]
		public var __isInitialized__:Boolean = true;
		
		[Transient]
		public var __isCollectionInitializedMap__:Object = new Object();
		
		[Id]
		public var id:String;
		
		public function get phoneNumber():String { checkIsInitialized("phoneNumber"); return _phoneNumber; }
		public function set phoneNumber(value:String):void { _phoneNumber = value; }
		private var _phoneNumber:String;
		
		[Association]
		public function get patient():Patient { checkIsInitialized("patient"); return _patient; }
		public function set patient(value:Patient):void { _patient = value; }
		private var _patient:Patient;
		
		public function PhoneNumberEntityBase() {
		}
		
		public function toString():String {
			return "[PhoneNumber id=" + id + "]";
		}
		
		private function checkIsInitialized(property:String):void {
			if (!__isInitialized__ && __isUnserialized__)
				throw new FlextrineError("Attempt to get property '" + property + "' on unitialized PhoneNumber.  Consider using EntityManager::require or eager loading.", FlextrineError.ACCESSED_UNITIALIZED_ENTITY);
		}
		
	}

}
